<template>
  <a-layout id="components-layout-demo-fixed-sider">
    <a-layout-sider :style="{ overflow: 'auto', height: '100vh', position: 'fixed', left: 0 }">
      <div class="logo" style>
        <img style="width:23px;height:23px" src="../../assets/logo.png" alt />
        <span style="font-size:20px">新龙后台</span>
      </div>
      <a-menu theme="dark" mode="inline" :default-selected-keys="['1']">
        <a-menu-item key="1">
          <a-icon type="user" />
          <span class="nav-text">订单查询</span>
        </a-menu-item>
        <a-menu-item key="2">
          <a-icon type="video-camera" />
          <span class="nav-text">库存查询</span>
        </a-menu-item>
        <a-menu-item key="3">
          <a-icon type="upload" />
          <span class="nav-text">库存动态</span>
        </a-menu-item>
        <a-menu-item key="4">
          <a-icon type="bar-chart" />
          <span class="nav-text">添加商品</span>
        </a-menu-item>
        <a-menu-item key="5">
          <a-icon type="cloud-o" />
          <span class="nav-text">销售商品</span>
        </a-menu-item>
      </a-menu>
    </a-layout-sider>
    <a-layout :style="{ marginLeft: '200px' }">
      <a-layout-header
        :style="{ position: 'fixed' ,background:'#fff',width:'88%',boxShadow:'0px 2px 2px 0px rgba(0, 0, 0, 0.1)',zIndex: 1}"
      >
        <Nav />
      </a-layout-header>
      <a-layout-content :style="{ margin: '64px 16px 0', overflow: 'initial' }">
        <div :style="{ padding: '24px', background: '#fff', textAlign: 'center' }">
          <table>
            <router-view></router-view>
          </table>
        </div>
      </a-layout-content>
      <a-layout-footer :style="{ textAlign: 'center', margin:'0 auto'}">
        <Foot />
      </a-layout-footer>
    </a-layout>
  </a-layout>
</template>
<script>
import Nav from "@/components/Nav/index";
import Foot from "@/components/Foot/index";
export default {
  components: {
    Nav,
    Foot
  }
};
</script>
<style>
#components-layout-demo-fixed-sider .logo {
  height: 32px;
  margin: 16px;
  background-color: rgba(0, 33, 64, 1);
  color: white;
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  align-items: center;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
</style>
